TARGET   = example

pathX86=./bin/x86/
pathARM=./bin/arm/

CFLAGS =
ifdef ARM
	CC     = arm-linux-gnueabihf-gcc
	path   = $(pathARM)
	LIBRARY += ./armlibs/
	INCLUDE += ./include/
else
	CC     = gcc
	path   = $(pathX86)
endif

ifdef WARNING
	CFLAGS   += -Wall -g
else
	CFLAGS   +=  -g
endif


SRC       =  example.c mt_timer.c #$(wildcard ./src/*.c)
#CFLAGS    = $(CFLAG)
LIBS      += -lpthread
LIBRARY   += 

$(TARGET):$(SRC)
	$(CC) $(CFLAGS) -o  $(path)$(TARGET) $(SRC)  $(LIBS) #-L$(LIBRARY) -I$(INCLUDE)
.PHONY:clean
clean:
	-rm -rf $(pathX86)$(TARGET) $(pathARM)$(TARGET)

